package com.newer.dao.mapper.sys;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.newer.dao.bean.sys.Permission;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface PermissionMapper extends BaseMapper<Permission> {
    int deleteByPrimaryKey(String id);

    @Override
    Integer insert(Permission record);

    int insertSelective(Permission record);

    Permission selectByPrimaryKey(String id);

    int updateByPrimaryKeySelective(Permission record);

    int updateByPrimaryKey(Permission record);

    List<Permission> selectByParams(Page<Permission> page, Permission record);

    @Select("select id from s_auth_permission where permission_code = #{permissionCode}")
    String selectPermissionCuntByCode(@Param("permissionCode") String permissionCode);

}